#ifndef QIHSUBSYSTEM_H
#define QIHSUBSYSTEM_H

#include "qihmodule.h"

#include <QString>
#include <QList>

#define IHCORE_NAME "InHand - Monitor"

#define IHCORE_VER_MAJOR 0x01
#define IHCORE_VER_MINOR 0x00
#define IHCORE_VER_BUILD 0x0000

// SubSystem version: major.minor.build
#define IHCORE_VERSION ( (IHCORE_VER_MAJOR << 8 | IHCORE_VER_MINOR) << 16 | IHCORE_VER_BUILD )

class IHCORE_EXPORT QihSubSystem : public QihModule
{
	Q_OBJECT

public:
	QihSubSystem(QObject *parent);
	~QihSubSystem();

public:
	// module management
	void addModule(QihModule* pModule);
	void removeModule(QihModule* pModule);
	void freeAllModules();
	QList<QihModule*> Modules() const { return _modules; }

	// subsystem information
	QString getName() const { return IHCORE_NAME; };  
	quint32 getVersion() const { return IHCORE_VERSION; };

protected:
	// override methods (QihModule)
	void doStart();
	void doStop();

private:
	QList<QihModule*> _modules;
};

#endif // QIHSUBSYSTEM_H
